package com.edu.neusoft.phone_sale.entity;

import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.Data;

import java.io.Serializable;

/**
 * 产品表，存储产品的详细信息(Products)表实体类
 */
@Data
public class Products extends Model<Products> {
    //产品ID，主键，自动递增
    @TableId
    private Integer productid;
    //产品名称，不能为空
    private String productname;
    //品牌ID，外键，引用Brands表的BrandID，不能为空
    private Integer brandid;
    //售价，不能为空，使用DECIMAL类型以存储精确的小数
    private Double saleprice;
    //库存数量，默认为0（注意：通常库存数量会单独管理在库存表中，这里为了简化示例而包含）
    private Integer stockquantity;
    //供应商ID，外键，引用Suppliers表的SupplierID，允许为空（在初始插入产品时可能尚未指定供应商）
    private Integer supplierid;


    public Integer getProductid() {
        return productid;
    }

    public void setProductid(Integer productid) {
        this.productid = productid;
    }

    public String getProductname() {
        return productname;
    }

    public void setProductname(String productname) {
        this.productname = productname;
    }

    public Integer getBrandid() {
        return brandid;
    }

    public void setBrandid(Integer brandid) {
        this.brandid = brandid;
    }

    public Double getSaleprice() {
        return saleprice;
    }

    public void setSaleprice(Double saleprice) {
        this.saleprice = saleprice;
    }

    public Integer getStockquantity() {
        return stockquantity;
    }

    public void setStockquantity(Integer stockquantity) {
        this.stockquantity = stockquantity;
    }

    public Integer getSupplierid() {
        return supplierid;
    }

    public void setSupplierid(Integer supplierid) {
        this.supplierid = supplierid;
    }

}

